{% extends "base.html" %}
{% block content %}
<section>
  <h1>James' Index Log - Past Indexes</h1>
</section>
<section>
  <h2>Past crawls</h2>
  <p>This page shows a record of all past crawls of jamesg.blog.</p>
  {% if past_indexes | length > 0 %}
  <table>
      <tr>
        <th>Total pages indexed</th>
        <th>Total images indexed</th>
        <th>Pages indexed in crawl</th>
        <th>Images indexed in crawl</th>
        <th>HTML content length</th>
        <th>Index start</th>
        <th>Index end</th>
        <th>Crawl duration</th>
      </tr>
      {% for c in past_indexes %}
      <tr>
          <td>{{ c[0] }}</td>
          <td>{{ c[1] }}</td>
          <td>{{ c[2] }}</td>
          <td>{{ c[3] }}</td>
          <td>{{ c[4] }}</td>
          <td>{{ c[5] }}</td>
          <td>{{ c[6] }}</td>
          <td>{{ c[7] }}</td>
      </tr>
      {% endfor %}
  </table>
  {% else %}
  <p>No crawls have been run yet.</p>
  {% endif %}
</section>
{% endblock %}